package com.silverbox.waimai.service.order.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.silverbox.waimai.entity.WaimaiItemDetail;
import com.silverbox.waimai.mapper.WaimaiItemDetailMapper;
import com.silverbox.waimai.service.order.WaimaiItemDetailService;

@Service
public class WaimaiItemDetailServiceImpl implements WaimaiItemDetailService {

	@Autowired
	private WaimaiItemDetailMapper waimaiItemDetailMapper;

	@Override
	public void addWaimaiItemDetail(List<WaimaiItemDetail> details) {
		waimaiItemDetailMapper.insertByBatch(details);
	}

    @Override
    public void addWaimaiItemDetail(WaimaiItemDetail itemDetail) {
        waimaiItemDetailMapper.insertSelective(itemDetail);
    }
}
